<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>Layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="lib/layui/css/layui.css"  media="all">
    <!-- 注意：如果你直接复制所有代码到本地，上述css路径需要改成你本地的 -->

</head>
<body>
<fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
    <legend>添加员工</legend>
</fieldset>
<form id="fm" class="layui-form" action="" lay-filter="example" method="post" enctype="multipart/form-data">
    <div class="layui-form-item">
        <label class="layui-form-label">姓名</label>
        <div class="layui-input-inline">
            <input id="name" type="text"  name="userName" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
        </div>
        <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">职位选择框</label>
        <div class="layui-input-inline">
            <select name="roleId" lay-verify="required" id="sel">
                <option value="">请选择</option>
                <template v-for="role in list">
                    <option :value="role.id">{{role.roleName}}</option>
                </template>
<!--                <option value="1">总管理员</option>-->
<!--                <option value="4">出库管理员</option>-->
<!--                <option value="3">入库管理员</option>-->
<!--                <option value="5">财务管理员</option>-->
<!--                <option value="2">库内管理员</option>-->
            </select>
        </div>
        <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">用户名</label>
        <div class="layui-input-inline">
            <input type="text" id="yhm" name="loginName" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
        </div>
        <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">密码</label>
        <div class="layui-input-inline">
            <input type="password" name="password" lay-verify="required|pass" placeholder="请输入密码" autocomplete="off" class="layui-input">
        </div>
        <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">手机号码</label>
        <div class="layui-input-inline">
            <input type="tel" name="phone" lay-verify="required|phone" placeholder="请输入手机号码" autocomplete="off" class="layui-input">
        </div>
        <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
    </div>
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">选择头像</label>
            <div class="layui-input-inline">
                <input style="display: none" id="file" type="file" name="headFileName" autocomplete="off" class="layui-input" lay-verify="required">
                <img id="img" width="50px" height="50px" src="" alt="点击">
            </div>
            <div class="layui-form-mid layui-word-aux"><span style="color: red">*</span></div>
        </div>
    </div>



    <div class="layui-form-item">
        <div class="layui-input-block">
<!--            <button type="submit" class="layui-btn" lay-submit="" lay-filter="demo1">立即添加</button>-->
            <input type="button" class="layui-btn" lay-submit="" lay-filter="demo1" value="立即添加">
<!--            <button type="reset" class="layui-btn layui-btn-primary">重置</button>-->
            <input type="reset" class="layui-btn layui-btn-primary">
        </div>
    </div>

</form>

<script src="lib/layui/layui.js" charset="utf-8"></script>
<script src="lib/vue.js"></script>
<script src="lib/jquery-3.4.1.min.js"></script>
<script>

    // function sele() {
    //     $.get("htz/role/selChoice",{token:1},function (data) {
    //         var list = data.obj;
    //         for (var i = 0; i <list.length ; i++) {
    //             var $option = $("<option value=\""+list[i].id+"\">"+list[i].roleName+"</option>")
    //             $("#sel").append($option);
    //         }
    //     })
    // }
</script>

<script type="text/javascript" src="lib/js/staff_add.js"></script>
<!-- 注意：如果你直接复制所有代码到本地，上述js路径需要改成你本地的 -->
<script>



</script>

</body>
</html>